let arr = [1,2,3,1,3,1,3]

//1、Set + Array.from
function unique(arr){
    let set = new Set(arr)
    let uniqueArr = Array.from(set)
    console.log(uniqueArr)
}
// unique(arr)

//2、Set + ...
function unique2(arr){
    let set = new Set(arr)
    let uniqueArr = [...set]
    console.log(uniqueArr)
}
unique2(arr)